//
//  NativeUIView.swift
//  Runner
//
//  Created by longxiaobai on 2024/8/2.
//

import SwiftUI

struct NativeUIView: View {
    @State var totalNumber: Int = 0
    var number: Int = 2
    
    var body: some View {
        VStack(content: {
            /*@START_MENU_TOKEN@*/Text("Placeholder")/*@END_MENU_TOKEN@*/.padding(8)
            Text("Hello, World").padding(8.0)
            Text("Number \(String(totalNumber))").padding(16.0)
            Button(action: {
                //action
                totalNumber += number
            }){
                Text("立即使用")
                    .font(.system(size: 17))
                    .foregroundColor(.white)
                    .padding()
                    .frame(width: 180)
                    .background(Color.green)
                    .cornerRadius(16)
            }
        })
    }
}

#Preview {
    NativeUIView()
}
